// JavaScript Document
function ticketYd(){
	var info="景点："+$("#scenery_name").text()+"，门票类型："+$("#ticket_info").val();
	$.ajax({
	    url:"../json/Mail_sendInfo",    //请求的url地址
	    dataType: "json",   //返回格式为json
	    async: true, //请求是否异步，默认为异步，这也是ajax重要特性
	    type: "POST",
	    data:{"t_info":info}
	});
	openYDwin();
}

function hotelYd(){
	var info="景点："+$("#scenery_name").text()+"，附近宾馆："+$("#hotel_info").val();
	$.ajax({
	    url:"../json/Mail_sendInfo",    //请求的url地址
	    dataType: "json",   //返回格式为json
	    async: true, //请求是否异步，默认为异步，这也是ajax重要特性
	    type: "POST",
	    data:{"h_info":info}
	});
	openYDwin();
}

function openYDwin(){
	var url="win.html";
	var w_sp1 = 400;
	var h_sp1 = 250;
	var iTop2 = (window.screen.availHeight - 20 - h_sp1) / 2;
	var iLeft2 = (window.screen.availWidth - 10 - w_sp1) / 2;
	var params = 'menubar:no;dialogHeight=' + h_sp1 + 'px;dialogWidth=' + w_sp1 + 'px;dialogLeft=';
	params +=iLeft2 + 'px;dialogTop=' + iTop2 + 'px;resizable=yes;scrollbars=0;resizeable=0;center=yes;location:no;status:no';
	window.showModalDialog(url, window, params);
}

//播放视频
function playVideo(val){
	var url="video.html?url="+val;
	var w_sp1 = 1024;
	var h_sp1 = 580;
	var iTop2 = (window.screen.availHeight - 20 - h_sp1) / 2;
	var iLeft2 = (window.screen.availWidth - 10 - w_sp1) / 2;
	var params = 'menubar:no;dialogHeight=' + h_sp1 + 'px;dialogWidth=' + w_sp1 + 'px;dialogLeft=';
	params +=iLeft2 + 'px;dialogTop=' + iTop2 + 'px;resizable=yes;scrollbars=0;resizeable=0;center=yes;location:no;status:no';
	window.showModalDialog(url, window, params);
}

